'use strict';

const router = require('koa-router')()
import CityHandle from '../controller/v1/cities'
import SearchPlace from '../controller/v1/search'
import Entry from '../controller/v1/entry'

router.get('/cities', CityHandle.getCity) // 获取定位城市，热门城市，所有城市
      .get('/cities/:id', CityHandle.getCityById) // 通过id获取城市信息
      .get('/pois', SearchPlace.search) // 关键词搜索地址
      .get('/pois/:geohash',CityHandle.pois) // 通过经纬度搜索精确地址
      .get('/index_entry', Entry.getEntry) // 获取所有商品分离

export default router